package algorithm.kalman;

public class GPSSingleData  {
    private float speed;
    private double lon;
    private double lat;
    private long timestamp;
    private float accuracy;

    public GPSSingleData(float speed, double lat, double lon, long timestamp, float accuracy) {
        this.speed = speed;
        this.lon = lon;
        this.lat = lat;
        this.timestamp = timestamp;
        this.accuracy = accuracy;
    }


    public float getSpeed() {
        return speed;
    }

    public void setSpeed(float speed) {
        this.speed = speed;
    }

    public double getLon() {
        return lon;
    }

    public void setLon(double lon) {
        this.lon = lon;
    }

    public double getLat() {
        return lat;
    }

    public void setLat(double lat) {
        this.lat = lat;
    }

    public long getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(long timestamp) {
        this.timestamp = timestamp;
    }

    public float getAccuracy() {
        return accuracy;
    }

    public void setAccuracy(float accuracy) {
        this.accuracy = accuracy;
    }

    @Override
    public String toString() {
        return speed + " " + lon + " " + lat + " " + timestamp;
    }

//    @Override
//    public int compareTo(Object o) {
//        if(this ==o){
//            return 0;
//        }
//        else if (o!=null && o instanceof GPSSingleData) {
//            GPSSingleData u = (GPSSingleData) o;
//            if(accuracy<=u.accuracy){
//                return -1;
//            }else{
//                return 1;
//            }
//        }else{
//            return -1;
//        }
//    }
}
